﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Linq.Expressions;
using System.Diagnostics;

namespace IRC.IRepairClouds.DataLayer.Expressions
{
    public static class ExpressionConvertExtensions
    {
        public static BinaryExpressionBuilder<T> ToExpressionBuilder<T>(this BinaryExpression expression)
        {
            return new BinaryExpressionBuilder<T>(expression);
        }

        public static ConditionalExpressionBuilder<T> ToExpressionBuilder<T>(this ConditionalExpression expression)
        {
            return new ConditionalExpressionBuilder<T>(expression);
        }

        public static ConstantExpressionBuilder<T> ToExpressionBuilder<T>(this ConstantExpression expression)
        {
            return new ConstantExpressionBuilder<T>(expression);
        }

        public static InvocationExpressionBuilder<T> ToExpressionBuilder<T>(this InvocationExpression expression)
        {
            return new InvocationExpressionBuilder<T>(expression);
        }

        public static LambdaExpressionBuilder<T> ToExpressionBuilder<T>(this LambdaExpression expression)
        {
            return new LambdaExpressionBuilder<T>(expression);
        }

        public static MemberExpressionBuilder<T> ToExpressionBuilder<T>(this MemberExpression expression)
        {
            return new MemberExpressionBuilder<T>(expression);
        }

        public static MethodCallExpressionBuilder<T> ToExpressionBuilder<T>(this MethodCallExpression expression)
        {
            return new MethodCallExpressionBuilder<T>(expression);
        }

        public static NewExpressionBuilder<T> ToExpressionBuilder<T>(this NewExpression expression)
        {
            return new NewExpressionBuilder<T>(expression);
        }

        public static NewArrayExpressionBuilder<T> ToExpressionBuilder<T>(this NewArrayExpression expression)
        {
            return new NewArrayExpressionBuilder<T>(expression);
        }

        public static MemberInitExpressionBuilder<T> ToExpressionBuilder<T>(this MemberInitExpression expression)
        {
            return new MemberInitExpressionBuilder<T>(expression);
        }

        public static ListInitExpressionBuilder<T> ToExpressionBuilder<T>(this ListInitExpression expression)
        {
            return new ListInitExpressionBuilder<T>(expression);
        }

        public static ParameterExpressionBuilder<T> ToExpressionBuilder<T>(this ParameterExpression expression)
        {
            return new ParameterExpressionBuilder<T>(expression);
        }

        public static TypeBinaryExpressionBuilder<T> ToExpressionBuilder<T>(this TypeBinaryExpression expression)
        {
            return new TypeBinaryExpressionBuilder<T>(expression);
        }

        public static UnaryExpressionBuilder<T> ToExpressionBuilder<T>(this UnaryExpression expression)
        {
            return new UnaryExpressionBuilder<T>(expression);
        }
    }
}
